import request from '@/service'
const http = (data)=>{
  return new request(data)
}

enum roadWayApiEnum {
  getTime = '/api/qualityKanban/getTime',
  onlineAmr = '/agvapi/api/amr/onlineAmr',
  workShopData = '/api/board/workShopData',
  login = '/api/sysAuth/login',
  getAGV = '/api/agv/onlineVehicles',
  workOrder = '/api/workOrder/page',
  workOrderList = '/api/workOrder/list',
  equipmentDropdown = '/api/workOrder/equipmentDropdown'
}

export const getTime = (data?: any) => http().GET({ url: roadWayApiEnum.getTime, data })
export const onlineAmr = (data?: any) => http({agvAPI:true}) .GET({ url: roadWayApiEnum.onlineAmr, data })
export const workShopData = (data?: any) => http().GET({ url: roadWayApiEnum.workShopData, data })
export const login = (data?: any) => http().POST({ url: roadWayApiEnum.login, data })
export const getAGV = (data?: any) => http().POST({ url: roadWayApiEnum.getAGV, data })
export const workOrder = (data?: any) => http().POST({ url: roadWayApiEnum.workOrder, data })
export const getworkOrderList = (data?: any) => http().GET({ url: roadWayApiEnum.workOrderList, data })
export const equipmentDropdown = (data?: any) => http().GET({ url: roadWayApiEnum.equipmentDropdown, data })